package com.ran.providermodule.provider;

import android.content.ContentValues;
import android.content.Context;
import android.support.test.InstrumentationRegistry;

import org.junit.Test;

import static org.junit.Assert.*;

/**
 * Created by ran on 2017/10/21.
 */
public class ProviderDaoTest {
    @Test
    public void batchInsert() throws Exception {

    }

    @Test
    public void query1() throws Exception {
        ProviderDao.getInstance(appContext).query();
    }

    Context appContext = InstrumentationRegistry.getTargetContext();
    @Test
    public void insert() throws Exception {
        ContentValues contentValues=new ContentValues();
        contentValues.put("title","ranqiliang");
        contentValues.put("name","ranqiliang");
        contentValues.put("date_added","20171021");
        contentValues.put("SEX","man");
        ProviderDao.getInstance(appContext).insert(contentValues);
    }

}